<%@ page import="com.education.service.bean.ActivityBean" %>
<%@ page import="java.util.List" %><%--
  Created by IntelliJ IDEA.
  User: Fan307
  Date: 2016/11/21
  Time: 20:25
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>addSchoolFolder.jsp </title>
</head>
<body>
    <script type="text/javascript">
        function getSelectedFolder() {
            var catagory = document.getElementById("catagoryFolder").value;
            var school = document.getElementById("SchoolFolder").value;
            var schoolfolder = catagory + "\\" + school + "\\";
            alert(schoolfolder);

            window.location.href = "/admin/addSchoolFolder1.jsp?schoolFolder=" + schoolfolder;

        }

    </script>
    <h3>选择Catagory下的目录</h3>
    <select id="catagoryFolder" name="catagoryName">
    <%
        List<ActivityBean> infoCatagortyBean = (List) request.getAttribute("infocatagorybean");
        if(infoCatagortyBean.size() == 0)
        {
            out.println("当前选项为空");
        }
        else {
            for(int i=0;i<infoCatagortyBean.size();i++)
            {
                String catagoryValue = infoCatagortyBean.get(i).getValue();
                //String catagoryName = infoCatagortyBean.get(i).getName();
    %>
    <option value="<%=catagoryValue%>"><%=catagoryValue%></option>
    <%
            }
        }
    %>
    </select>
<input type="text"  id="SchoolFolder" />
    <input type="button" value="确定" onclick="getSelectedFolder()"/>

</body>
</html>
